var sign = require('./sign.js');

exports.getList = function(req,res){
	sign.dataReq(req,req.session.token,req.body,'rework/getList','post',function(ResData){
		if(ResData!=''){
			res.send(ResData);
		}else{
			res.send('暂时没有数据');
		}
	})
}

exports.reworkFile = function(req,res){
	sign.importfileReq(req,req.session.token,req,'rework/reworkFile','post',function(ResData){
		if(ResData!=''){
			res.send(ResData);
		}
	})
}

// exports.addOrder = function(req,res){
// 	sign.importfileReq(req,req.session.token,req,'order/addOrder','post',function(ResData){
// 		if(ResData!=''){
// 			res.send(ResData);
// 		}
// 	})

exports.deviceInfo = function(req,res){
	req.body.type = Number(req.body.type);
  // var data = JSON.parse(req.body);
	sign.dataReq(req,req.session.token,req.body,'device/deivceInfo','post',function(ResData){
		var ResData = {rows:ResData};
		console.log(ResData);
		if(ResData!=''){
			res.send(ResData);
		}else{
			res.send('暂时没有数据');
		}
	})
}

